<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core"
      xmlns:p="http://primefaces.org/ui">

    <ui:composition>

        <p:dialog id="ItemComprovanteEntregaCreateDlg" widgetVar="ItemComprovanteEntregaCreateDialog" modal="true" resizable="false" appendTo="@(body)" header="#{bundle.CreateItemComprovanteEntregaTitle}">
            <h:form id="ItemComprovanteEntregaCreateForm">
                <h:panelGroup id="display">
                    <p:panelGrid columns="2" rendered="#{itemComprovanteEntregaController.selected != null}">
                        <p:outputLabel value="#{bundle.CreateItemComprovanteEntregaLabel_qtFaturar}" for="qtFaturar" />
                        <p:inputText id="qtFaturar" value="#{itemComprovanteEntregaController.selected.qtFaturar}" title="#{bundle.CreateItemComprovanteEntregaTitle_qtFaturar}" required="true" requiredMessage="#{bundle.CreateItemComprovanteEntregaRequiredMessage_qtFaturar}"/>
                        <p:outputLabel value="#{bundle.CreateItemComprovanteEntregaLabel_vlFaturar}" for="vlFaturar" />
                        <p:inputText id="vlFaturar" value="#{itemComprovanteEntregaController.selected.vlFaturar}" title="#{bundle.CreateItemComprovanteEntregaTitle_vlFaturar}" required="true" requiredMessage="#{bundle.CreateItemComprovanteEntregaRequiredMessage_vlFaturar}"/>
                        <p:outputLabel value="#{bundle.CreateItemComprovanteEntregaLabel_comprovanteEntrega}" for="comprovanteEntrega" />
                        <p:selectOneMenu id="comprovanteEntrega" value="#{itemComprovanteEntregaController.selected.comprovanteEntrega}" required="true" requiredMessage="#{bundle.EditItemComprovanteEntregaRequiredMessage_comprovanteEntrega}">
                            <f:selectItems value="#{comprovanteEntregaController.itemsAvailableSelectOne}"
                                           var="comprovanteEntregaItem"
                                           itemValue="#{comprovanteEntregaItem}"/>
                        </p:selectOneMenu>
                        <p:outputLabel value="#{bundle.CreateItemComprovanteEntregaLabel_itemContrato}" for="itemContrato" />
                        <p:selectOneMenu id="itemContrato" value="#{itemComprovanteEntregaController.selected.itemContrato}" required="true" requiredMessage="#{bundle.EditItemComprovanteEntregaRequiredMessage_itemContrato}">
                            <f:selectItems value="#{itemContratoController.itemsAvailableSelectOne}"
                                           var="itemContratoItem"
                                           itemValue="#{itemContratoItem}"/>
                        </p:selectOneMenu>
                    </p:panelGrid>
                    <p:commandButton actionListener="#{itemComprovanteEntregaController.create}" value="#{bundle.Save}" update="display,:ItemComprovanteEntregaListForm:datalist,:growl" oncomplete="handleSubmit(args,'ItemComprovanteEntregaCreateDialog');"/>
                    <p:commandButton value="#{bundle.Cancel}" onclick="ItemComprovanteEntregaCreateDialog.hide()"/>
                </h:panelGroup>
            </h:form>
        </p:dialog>

    </ui:composition>
</html>
